#ifndef __USART_PROTOCOL_H__
#define __USART_PROTOCOL_H__

#include "main.h"

#define MaxLength               16

#define COMM6_RX_FREE_1         0
#define COMM6_RX_FREE_2         1
#define COMM6_RX_FLAG						2
#define COMM6_RX_START          3
#define COMM6_RX_DATA           4
#define COMM6_RX_END            5
							

#define HEART_DATA_LENGTH				0
#define FOCUS_DATA_LENGTH				1
#define BUFF_DATA_LENGTH				2
#define ENEMYPOS_DATA_LENGTH 		3
#define AIM_DATA_LENGTH		    	3



void UART4_rx_handle(void);
void debug_rx_handle(void);
void Send_Curve_To_PC(void);
void usart_tx_handle(USART_TypeDef* USARTx, UCHAR8* pTxBuf, UCHAR8 length);
void USART_Transmit(USART_TX_TypeDef* USARTx);
USHORT16 USART_Receive(USART_RX_TypeDef* USARTx);
#endif
